const fetch= require('node-fetch');
function *gen(){
    var url  = "https://api.douban.com/v2/movie/27663742";
    var result = yield fetch(url);
    console.log(result);
}
var g = gen();
var res = g.next()
res.value.then(data=>{
     return data.json()
}).then(data=>{
    g.next(data)
})